package com.bbs.utils;

import javax.mail.Authenticator;
import javax.mail.PasswordAuthentication;

/**
 * 继承邮件发送抽象类，构造授权信息
 */
public class MyAuthenticator extends Authenticator {
    private static final String USER = "979583477@qq.com"; // 发件人称号，同邮箱地址
    private static final String PASSWORD = "mgkkmfjggfqvbahe"; // 如果是qq邮箱可以使户端授权码
    public MyAuthenticator() {
        super();
    }
    public PasswordAuthentication getPasswordAuthentication() {
        return new PasswordAuthentication(USER,PASSWORD);
    }
}
